// source --> https://www.cinofollie.club/wp-content/plugins/staffer/public/js/staffer-scripts.js?ver=2.1.0
(function( $ ) {
'use strict';
var getUrlParameter = function getUrlParameter(sParam) {
var sPageURL = decodeURIComponent(window.location.search.substring(1)),
sURLVariables = sPageURL.split('&'),
sParameterName,
i;
for (i = 0; i < sURLVariables.length; i++) {
sParameterName = sURLVariables[i].split('=');
if (sParameterName[0] === sParam) {
return sParameterName[1] === undefined ? true : sParameterName[1];
}
}
};
$(document).ready( function(e) {
$('a.cw-launch-staffer-modal').on('click', function(e) {
var bio,img,name,title, id, slug,
department,website,phone,email,fb,
linkedin,twitter,gplus,youtube,
instagram,github, iconArr,
iconOutput = '';
bio = $(this).attr('data-bio');
img = $(this).attr('data-large-image');
img = img.replace('aligncenter', 'alignleft');
img = img.replace('alignleft', 'alignleft cw-staffer-max-image');
name = $(this).attr('data-name');
title = $(this).attr('data-title');
department = $(this).attr('data-departments');
phone = $(this).attr('data-phone');
email = $(this).attr('data-email');
website = $(this).attr('data-website');
id = $(this).attr('data-staff-id');
slug = $(this).attr('data-staff-slug');
fb = $(this).attr('data-facebook');
twitter = $(this).attr('data-twitter');
linkedin = $(this).attr('data-linkedin');
gplus = $(this).attr('data-google-plus');
youtube = $(this).attr('data-youtube');
instagram = $(this).attr('data-instagram');
github = $(this).attr('data-github');
iconArr = {
'facebook' : fb,
'twitter' : twitter,
'linkedin' : linkedin,
'googleplus' : gplus,
'youtube' : youtube,
'instagram' : instagram,
'github' : github
}
$.each( iconArr, function( key, value ) {
if( value !== '' ) {
iconOutput += '';
}
});
$('.cw-staffer-modal .staff-name').text(name);
$('.cw-staffer-modal .cw-modal-header .staff-title').text(title);
$('.cw-staffer-modal .cw-modal-header .staff-department').text(department);
$('.cw-staffer-modal .cw-modal-header .social-icons').html(iconOutput);
if( website ) {
$('.cw-staffer-modal .cw-modal-header .staff-website').html('' + website + '');
} else {
$('.cw-staffer-modal .cw-modal-header .staff-website').html('');
}
$('.cw-staffer-modal .cw-modal-header .staff-phone').text(phone);
$('.cw-staffer-modal .cw-modal-header .staff-email').text(email);
$('.cw-staffer-modal .cw-modal-body').html(img + bio);
$('.cw-staffer-modal').show();
$('body').addClass('cw-staffer-overlay');
$('html').addClass('cw-staffer-overlay');
var state = { name: slug };
history.pushState(state, '', '?uid=' + slug );
return false;
});
$('.cw-staffer-modal .cw-modal-close').on('click', function(e) {
$('.cw-staffer-modal').hide();
$('body').removeClass('cw-staffer-overlay');
$('html').removeClass('cw-staffer-overlay');
var state = { name: 'none' };
history.replaceState(state, '', '?' );
return false;
});
if( $('body').hasClass('staffer-main-page') ) {
var staff_name = getUrlParameter('uid');
if( staff_name ) {
$('a.cw-launch-staffer-modal[data-staff-slug="' + staff_name + '"]').trigger('click');
}
$('.staffer-staff-email').each( function(i,obj) {
var email = $(this).parent().find('a[data-email]').attr('data-email');
$(this).find('em').text( email );
});
}
});
})( jQuery );
// source --> https://www.cinofollie.club/wp-content/plugins/duracelltomi-google-tag-manager/js/gtm4wp-contact-form-7-tracker.js?ver=1.10.1
jQuery( function() {
jQuery( ".wpcf7" )
.on( 'wpcf7mailsent', function( e ) {
var gtm4wp_cf7formid = '(not set)';
if ( e && e.detail && e.detail.contactFormId ) {
gtm4wp_cf7formid = e.detail.contactFormId;
} else if ( e && e.originalEvent && e.originalEvent.detail && e.originalEvent.detail.contactFormId ) {
gtm4wp_cf7formid = e.originalEvent.detail.contactFormId;
}
var gtm4wp_cf7forminputs = [];
if ( e && e.detail && e.detail.inputs ) {
gtm4wp_cf7forminputs = e.detail.inputs;
} else if ( e && e.originalEvent && e.originalEvent.detail && e.originalEvent.detail.inputs ) {
gtm4wp_cf7forminputs = e.originalEvent.detail.inputs;
}
window[ gtm4wp_datalayer_name ].push({
'event': 'gtm4wp.contactForm7Submitted',
'gtm4wp.cf7formid': gtm4wp_cf7formid,
'gtm4wp.cf7inputs': gtm4wp_cf7forminputs
});
});
});
// source --> https://www.cinofollie.club/wp-content/plugins/duracelltomi-google-tag-manager/js/gtm4wp-form-move-tracker.js?ver=1.10.1
jQuery( function() {
jQuery( ":input" )
.on( "focus", function() {
var input = jQuery(this);
var inputID = input.attr("id") || "(no input ID)";
var inputName = input.attr("name") || "(no input name)";
var inputClass = input.attr("class") || "(no input class)";
var form = jQuery(this.form);
var formID = form.attr("id") || "(no form ID)";
var formName = form.attr("name") || "(no form name)";
var formClass = form.attr("class") || "(no form class)";
window[ gtm4wp_datalayer_name ].push({
'event' : 'gtm4wp.formElementEnter',
'inputID' : inputID,
'inputName' : inputName,
'inputClass': inputClass,
'formID' : formID,
'formName' : formName,
'formClass': formClass
});
})
.on( "blur", function() {
var input = jQuery(this);
var inputID = input.attr("id") || "(no input ID)";
var inputName = input.attr("name") || "(no input name)";
var inputClass = input.attr("class") || "(no input class)";
var form = jQuery(this.form);
var formID = form.attr("id") || "(no form ID)";
var formName = form.attr("name") || "(no form name)";
var formClass = form.attr("class") || "(no form class)";
window[ gtm4wp_datalayer_name ].push({
'event' : 'gtm4wp.formElementLeave',
'inputID' : inputID,
'inputName' : inputName,
'inputClass': inputClass,
'formID' : formID,
'formName' : formName,
'formClass': formClass
});
});
});
// source --> https://www.cinofollie.club/wp-content/plugins/duracelltomi-google-tag-manager/js/gtm4wp-social-tracker.js?ver=1.10.1
jQuery( function() {
if ( typeof FB != "undefined" ) {
FB.Event.subscribe( 'edge.create', function( href, widget ) {
window[ gtm4wp_datalayer_name ].push({
'event': 'gtm4wp.socialAction',
'network': 'facebook',
'socialAction': 'like',
'opt_target': href,
'opt_pagePath': window.location.href
});
});
FB.Event.subscribe( 'edge.remove', function( href, widget ) {
window[ gtm4wp_datalayer_name ].push({
'event': 'gtm4wp.socialAction',
'network': 'facebook',
'socialAction': 'unlike',
'opt_target': href,
'opt_pagePath': window.location.href
});
});
FB.Event.subscribe( 'comment.create', function( href, commentID ) {
window[ gtm4wp_datalayer_name ].push({
'event': 'gtm4wp.socialAction',
'network': 'facebook',
'socialAction': 'comment',
'opt_target': href,
'opt_pagePath': window.location.href
});
});
FB.Event.subscribe( 'comment.remove', function( href, commentID ) {
window[ gtm4wp_datalayer_name ].push({
'event': 'gtm4wp.socialAction',
'network': 'facebook',
'socialAction': 'uncomment',
'opt_target': href,
'opt_pagePath': window.location.href
});
});
FB.Event.subscribe( 'message.send', function( response ) {
window[ gtm4wp_datalayer_name ].push({
'event': 'gtm4wp.socialAction',
'network': 'facebook',
'socialAction': 'send',
'opt_target': response,
'opt_pagePath': window.location.href
});
});
} // end of Facebook social events
if ( typeof window.twttr == "undefined" ) {
window.twttr = (function ( d, s, id ) {
var t, js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return; js=d.createElement(s); js.id=id;
js.src="https://platform.twitter.com/widgets.js"; fjs.parentNode.insertBefore(js, fjs);
return window.twttr || (t = {
_e: [],
ready: function(f) {
t._e.push(f);
}
});
} (document, "script", "twitter-wjs"));
} // end of loading Twitter JS
if ( typeof window.twttr != "undefined" ) {
window.twttr.ready(function ( twttr ) {
twttr.events.bind( 'tweet', function ( intent_event ) {
if ( intent_event ) {
var label = intent_event.data.tweet_id;
if (typeof label != 'undefined' && label) {
if(label == 'label'){
label = window.location.href;
}
}else{
label = window.location.href;
}
window[ gtm4wp_datalayer_name ].push({
'event': 'gtm4wp.socialAction',
'network': 'twitter',
'socialAction': 'tweet',
'opt_target': label,
'opt_pagePath': window.location.href
});
}
});
window.twttr.events.bind( 'follow', function ( intent_event ) {
if ( intent_event ) {
var label = intent_event.data.user_id + " (" + intent_event.data.screen_name + ")";
window[ gtm4wp_datalayer_name ].push({
'event': 'gtm4wp.socialAction',
'network': 'twitter',
'socialAction': 'follow',
'opt_target': label,
'opt_pagePath': window.location.href
});
}
});
});
}
});
// source --> https://www.cinofollie.club/wp-content/themes/Minamaze_Pro/lib/scripts/plugins/sticky/jquery.sticky.js?ver=true
// Sticky Plugin v1.0.0 for jQuery
// =============
// Author: Anthony Garand
// Improvements by German M. Bravo (Kronuz) and Ruud Kamphuis (ruudk)
// Improvements by Leonardo C. Daronco (daronco)
// Created: 2/14/2011
// Date: 2/12/2012
// Website: http://labs.anthonygarand.com/sticky
// Description: Makes an element on the page stick on the screen as you scroll
// It will only set the 'top' and 'position' of your element, you
// might need to adjust the width in some cases.
(function($) {
var defaults = {
topSpacing: 0,
bottomSpacing: 0,
className: 'is-sticky',
wrapperClassName: 'sticky-wrapper',
center: false,
getWidthFrom: ''
},
$window = $(window),
$document = $(document),
sticked = [],
windowHeight = $window.height(),
scroller = function() {
var scrollTop = $window.scrollTop(),
documentHeight = $document.height(),
dwh = documentHeight - windowHeight,
extra = (scrollTop > dwh) ? dwh - scrollTop : 0;
for (var i = 0; i < sticked.length; i++) {
var s = sticked[i],
elementTop = s.stickyWrapper.offset().top,
etse = elementTop - s.topSpacing - extra;
if (scrollTop <= etse) {
if (s.currentTop !== null) {
s.stickyElement
.css('position', '')
.css('top', '');
s.stickyElement.parent().removeClass(s.className);
s.currentTop = null;
}
}
else {
var newTop = documentHeight - s.stickyElement.outerHeight()
- s.topSpacing - s.bottomSpacing - scrollTop - extra;
if (newTop < 0) {
newTop = newTop + s.topSpacing;
} else {
newTop = s.topSpacing;
}
if (s.currentTop != newTop) {
s.stickyElement
.css('position', 'fixed')
.css('top', newTop);
if (typeof s.getWidthFrom !== 'undefined') {
s.stickyElement.css('width', $(s.getWidthFrom).width());
}
s.stickyElement.parent().addClass(s.className);
s.currentTop = newTop;
}
}
}
},
resizer = function() {
windowHeight = $window.height();
},
methods = {
init: function(options) {
var o = $.extend(defaults, options);
return this.each(function() {
var stickyElement = $(this);
var stickyId = stickyElement.attr('id');
var wrapper = $('